< previous page page_606 next page >

Page 606
8694cbadb9b1ef7075903f6f95fc1db2.gif
Unload Me
End Sub

Private Sub cmdSearch_Click()
If optLastName Then
    ADODC1.RecordSource = Select addressid, LastName, firstname, _
    firstname &  _
       & Lastname as fullname from [address entry] where lastname _
    like  _
      & txtSearch.Text & *
ElseIf optFirstname Then
    ADODC1.RecordSource = Select addressid, LastName, firstname, _
    firstname &  _
       & Lastname as fullname from [address entry] where firstname _
    like  _
      & txtSearch.Text & *
End If
ADODC1.Requery
1stNames.Refresh
1stNames.Visible = True
End Sub

Private Sub Form_Load()
txtSearch.Text = 
End Sub

Private Sub 1stNames_DblClick()
ADODC1.RecordSet.Find fullname =  & 1stNames.BoundText & , _
  adSearchForward
frmAddressEntry.sqlEntry = select * from [Address Entry] Where _
[AddressID] =  & Data1.Recordset.Fields(addressid)
frmAddressEntry.Show

End Sub

After adding all the controls, resize the DBListbox to fill the area as shown in Figure A.3. Also, set the DBListbox's Visible property to False.
Day 11, Enhancing the Application
Quiz
8694cbadb9b1ef7075903f6f95fc1db2.gif
1. A project group includes several different projects, such as a Standard EXE project and one or more ActiveX control projects.

 
< previous page page_606 next page >

If you like this book, buy it!